package vn.fpt.fsoft.autotest.userDAO;

import static org.junit.Assert.*;

import org.junit.Test;

import vn.fpt.fsoft.dao.UserDAO;
import vn.fpt.fsoft.autotest.database.UserDBWithOneRows;

public class GetUserByUsername {

    @Test
    public void testCase1() {
        UserDBWithOneRows.CreateData();
        UserDAO dao = new UserDAO();
        
        assertNotNull(dao.getUserByUsername("username1"));
    }
    
    @Test
    public void testCase2() {
        UserDBWithOneRows.CreateData();
        UserDAO dao = new UserDAO();
        
        assertNull(dao.getUserByUsername("username2"));
    }
}
